_base_ = [
    'cls_ss_rd_base.py'
]

norm_cfg = dict(type='SyncBN', requires_grad=True)
data = dict(
    samples_per_gpu=4,
    workers_per_gpu=4,)

model = dict(
    type='OrientedRCNN',
    pretrained='/data1/users/zhengzhiyu/mtp_workplace/mtpft_hwexp/pretrained/rsp-resnet-50-ckpt.pth',
    backbone=dict(
        type='Our_ResNet',
        layers=[3,4,6,3],
        norm_cfg = norm_cfg
        ),
    neck=dict(
        type='FPN',
        in_channels=[256, 512, 1024, 2048],
        out_channels=256,
        num_outs=5
        ),
    cls_head=dict(
        type='MultiSceneClsHead',
        in_channels=256,
        num_classes=13,
        loss_decode=dict(
            type='CrossEntropyLoss', use_sigmoid=True, loss_weight=1.0, loss_name='loss_scene_cls')),
)

# model training and testing settings

optimizer = dict(type='SGD', lr=0.005, momentum=0.9, weight_decay=0.0001)
optimizer_config = dict(grad_clip=dict(max_norm=35, norm_type=2))
# learning policy
lr_config = dict(
    policy='step',
    warmup='linear',
    warmup_iters=500,
    warmup_ratio=0.001,
    step=[24, 40])
total_epochs = 49

checkpoint_config = dict(interval=4, save_last=True, max_keep_ckpts=3)
evaluation = dict(interval=4, metric_det='mAP', metric_seg ='mIoU', metric_cls='f1_score', save_best='all', rule='greater', pre_eval=True)